#ifndef GTKMM_EXAMPLEWINDOW_H
#define GTKMM_EXAMPLEWINDOW_H

#include <gtkmm.h>
#include <list>
#include <libxml++/libxml++.h>
#include "myarea.h"
#include "rectangle.h"
#include "listview.h"

class ExampleWindow : public Gtk::Window
{
public:
	ExampleWindow();
	virtual ~ExampleWindow();

protected:
	//Signal handlers:
	virtual void on_menu_file_new_generic();
	virtual void on_menu_file_quit();
	virtual void on_menu_others();
	virtual void on_menu_file_save();
	virtual void register_stock_items();
	virtual void add_stock_item(const Glib::RefPtr<Gtk::IconFactory> & factory,
                      const std::string& filepath,
                      const Glib::ustring& id, const Glib::ustring& label);

	virtual void on_menu_file_open();


	//Member functions
	void parseFile(std::string filename);
	void verify();
	void focus();
	void save();
	void autofit();

	void saveFile(std::string filename);
	void ga();


	//Child widgets:
	Rectangle* space;
	MyArea area;

	Gtk::VBox m_Box;
	Gtk::HPaned m_HBox;
	Gtk::HBox m_HBox2;
	Gtk::Frame frame1, frame2;

	Glib::RefPtr<Gtk::UIManager> m_refUIManager;
	Glib::RefPtr<Gtk::ActionGroup> m_refActionGroup;

	Gtk::ScrolledWindow m_ScrolledWindow,;
	Gtk::TreeView m_TreeView;
	Glib::RefPtr<Gtk::ListStore> m_refTreeModel;
	Gtk::Adjustment m_adjustment;
	Gtk::HScale m_HScale;
	Gtk::Label m_Label_zoom;

	//Member Objects for processing

	ModelColumns m_Columns;
};

#endif //GTKMM_EXAMPLEWINDOW_H
